part of 'fragment.dart';

class _AccountOverviewFragmentWlocStateFactory {
  const _AccountOverviewFragmentWlocStateFactory._internal();

  static const _instance = _AccountOverviewFragmentWlocStateFactory._internal();

  factory _AccountOverviewFragmentWlocStateFactory() {
    return _instance;
  }

  _AccountOverviewFragmentWlocState create({
    required AccountOverviewFragmentBlocState blocState,
  }) {
    if (blocState is InitialAccountOverviewFragmentBlocState) {
      return const _InitialAccountOverviewFragmentWlocState();
    }

    if (blocState is LoadingAccountOverviewFragmentBlocState) {
      return const _LoadingAccountOverviewFragmentWlocState();
    }

    if (blocState is LoadedAccountOverviewFragmentBlocState) {
      return _LoadedAccountOverviewFragmentWlocState(
        user: blocState.user,
        premiumAccessActive: blocState.premiumAccessActive,
      );
    }

    throw UnimplementedError();
  }
}
